class Solution:
    def canBeTypedWords(self, text: str, brokenLetters: str) -> int:
        text = text.split(' ')
        ans = len(text)
        for i in range(len(text)):
            for j in range(len(text[i])):
                if text[i][j] in brokenLetters:
                    ans -= 1
                    break
        return ans